<template>
  <el-container class="home-container">
    <el-container>
      <!-- 内容主体 -->
      <el-main>
        <router-view></router-view>
      </el-main>
    </el-container>
    <el-footer>
      <el-menu :default-active="activeIndex" class="el-menu-demo" router mode="horizontal" @select="handleSelect">
        <el-menu-item index="/gDisplay">首页</el-menu-item>
        <el-menu-item index="/phoneequip">设备绑定</el-menu-item>
        <el-menu-item index="/phoneme">我的</el-menu-item>
      </el-menu>
      <div class="line"></div>
    </el-footer>
  </el-container>
</template>
<script>
export default {
  data() {
    return {
      activeIndex: '/gDisplay',
      activeIndex2: '1'
    }
  },
  // 是否折叠
  created () {
  },
  methods: {
    handleSelect(key, keyPath) {
      console.log(key, keyPath)
    },
    logout () {
      window.sessionStorage.clear()
      this.$router.push('/mlogin')
    }
  }
}
</script>

<style lang="less" scoped>
  .home-container{
    height: 100%;
  }
  .el-main{
    background-color: #eaedf1;
  }
  .el-menu-demo{
    width: 33%;
    text-align: center;
  }
</style>
